﻿#include "crashSuper.h"

double crashNormal::acceptCrash(double money)
{
    return money;
}

double crashRebate::acceptCrash(double money)
{
    return money * moneyRebate;
}

double CrashReturn::acceptCrash(double money)
{
    if (money >= moneyCondition)
        return money - int(money / moneyCondition) * moneyReturn;
    else
        return money;
}
